import Vue from 'vue'
import Vuex from 'vuex'
//引入三方vuex-persistedstate
import createPersistedState from 'vuex-persistedstate'
import product from './modules/product'
import adv from './modules/adv'
//安装使用Vuex
Vue.use(Vuex)
const store = new Vuex.Store({
  //数据存储
  plugins: [
    createPersistedState({
      key: 'zhaizijing',
    }),
  ],
  modules: {
    product,
    adv,
  },
})
export default store
